package com.kehutong.admin.entity;

import org.coraframework.bean.valid.CheckField;
import org.coraframework.json.annotation.JSONField;
import org.coraframework.orm.Entity;
import org.coraframework.orm.annotation.Column;
import org.coraframework.orm.annotation.Table;

/**
 * 字典
 * @author liuzhen (liuxing521a@163.com)
 * @createTime 2019年4月16日下午5:52:46
 */
@Table("sys_dict")
public class Dict extends Entity {

	private static final long serialVersionUID = 1L;

	protected Dict(String id) {
		super(id);
	}

	@CheckField("类型名不能为空")
	@Column(defValue = "NOT NULL",  comment = "标签名")
	private String label;	

	@CheckField("类型值不能为空")
	@Column(defValue = "NOT NULL",  comment = "数据值")
	private String value;	// 数据值

	@CheckField("类型不能为空")
	@Column(defValue = "NOT NULL",  comment = "数据类型")
	private String type;	// 类型

	@Column(defValue = "NOT NULL",  comment = "描述")
	private String description;

	@Column(defValue = "NOT NULL",  comment = "排序")
	private int sort;	// 排序
	
	@Column(comment = "描述")
	private String remarks;
	
	@JSONField(serialize=false)
	@Column(comment = "修改者")
	private String updateBy;

	@JSONField(serialize=false)
	@Column(comment = "创建者")
	private String createBy;
	
	@JSONField(serialize=false)
	@Column(comment = "逻辑删除")
	private boolean deleted;

	public String getLabel() {
		return label;
	}

	public void setLabel(String label) {
		this.label = label;
	}

	public String getValue() {
		return value;
	}

	public void setValue(String value) {
		this.value = value;
	}

	public String getType() {
		return type;
	}

	public void setType(String type) {
		this.type = type;
	}

	public String getDescription() {
		return description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	public int getSort() {
		return sort;
	}

	public void setSort(int sort) {
		this.sort = sort;
	}

	public String getRemarks() {
		return remarks;
	}

	public void setRemarks(String remarks) {
		this.remarks = remarks;
	}

	public String getUpdateBy() {
		return updateBy;
	}

	public void setUpdateBy(String updateBy) {
		this.updateBy = updateBy;
	}

	public String getCreateBy() {
		return createBy;
	}

	public void setCreateBy(String createBy) {
		this.createBy = createBy;
	}

	public boolean isDeleted() {
		return deleted;
	}

	public void setDeleted(boolean deleted) {
		this.deleted = deleted;
	}
}